package org.xiao.web.crawler.utils

import org.jsoup.Jsoup

import java.util.stream.Collectors

class JsoupBook{

   static def book(){
        try{
            def url='http://www.yishengchuancheng.com/i5331/'
            def doc=Jsoup.connect(url).get()
            def e=doc.select(".panel-body .list-group.list-charts")
            def aList=e[0].select("li a")
            aList.stream().map({a->"http://www.yishengchuancheng.com"+a.attr("href")}).collect(Collectors.toList())
        }catch (Exception e){
           e.printStackTrace()
        }

    }
}
